package com.buka.APi;

import com.baomidou.mybatisplus.extension.api.R;
import com.buka.entity.Pay;
import com.buka.entity.PayInfo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.cloud.openfeign.SpringQueryMap;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.*;

@Component
@FeignClient("pay")  //服务名
public interface PayApi {

    @RequestMapping("/pay/getInfo")
    public String getInfo();

    @PostMapping("/pay/savePay")
    public String savePay(@SpringQueryMap PayInfo payInfo);

    @GetMapping("/pay/get/{id}")
    public Long getById(@PathVariable("id")Long id);

    @PostMapping("/pay")
    public R insert(Pay pay);

    @RequestMapping("/pay/savePayByTCC")
    public R savePayByTCC(Pay pay);

}
